<?php

namespace V1;
class Share extends \ResourceClass
{
    public $isActive = true;
    public $remark = '分享接口';

    function __construct()
    {
        require_once(ROOT . 'lib/WxAuth.php');
    }

    public function get(array $req, array $post, &$result)
    {
        /*if (!isset($req['uid'])){
            return 'require UID';
        }
        if (!isset($req['url'])){
            return 'require url';
        }*/
       /* $url = 'http://sh.weixin.com/active/index';
        $result = $this->getSignature($url);
        try{
            return Response::Success($result,'SUCCESS');
        }catch (Exception $e){
            return Response::Error(0,'ERR');
        }*/
        //$url = $req['url'];
        $url = "http://sg.test.renrencaichang.com/active/index";
        $result = \WxAuth::getSignature($url);
    }
}